<template>
	<div class="system-role-dialog-container">
		<el-dialog :title="state.jsonObj.logName" v-model="state.dialog.isShowDialog" width="769px">
			<json-viewer
            boxed
            copyable
            theme="my-json-theme"
            :value="state.jsonObj"
          ></json-viewer>

		</el-dialog>
	</div>
</template>

<script setup lang="ts" name="systemRoleDialog">


// 定义子组件向父组件传值/事件
const emit = defineEmits(['refresh']);

// 定义变量内容
const roleDialogFormRef = ref();
const state = reactive({
	jsonObj:{},
	dialog: {
		isShowDialog: false,
		type: '',
		title: '',
		submitTxt: '',
	},
});

// 打开弹窗
const openDialog = (type: string, row: any) => {	
	state.dialog.isShowDialog = true;
	state.jsonObj = row
};
// 关闭弹窗
const closeDialog = () => {
	
	state.dialog.isShowDialog = false;
};
// 取消
const onCancel = () => {
	closeDialog();
};

const treeRef = ref();





// 暴露变量
defineExpose({
	openDialog,
});
</script>

<style scoped lang="scss">
.system-role-dialog-container {
	.menu-data-tree {
		width: 100%;
		border: 1px solid var(--el-border-color);
		border-radius: var(--el-input-border-radius, var(--el-border-radius-base));
		padding: 5px;
	}
}
</style>
